//
//  OosServiceActivityObject.m
//  Oos4ios
//
//  Created by Pablo Gonzalez on 4/4/11.
//  Copyright 2011 11870.com. All rights reserved.
//

#import <oos4ios/Model/OosServiceActivityObject.h>

@implementation OosServiceActivityObject

static NSString *fetchPredicate = @"service.slug = %@";

+ (OosServiceActivityObject *) objectFromServiceSlug:(NSString *)slug
{
	OosServiceActivityObject *result = nil;
    result = [super objectWithPredicate: fetchPredicate, slug];
	
    if (!result) {
        result = [super create];
        OosService *service = [OosService serviceFromSlug: slug];
        service.updated = nil;
        result.service = service;
    }
	
	return result;
}

@dynamic service;

@end
